﻿using System;
using System.Collections;
using System.Collections.Generic;


namespace BF
{
    public static class IEnumerableExtension
    {
        public static void ForEach<T>(this IEnumerable<T> self, Action<T> action)
        {
            if (self == null)
            {
                return;
            }
            foreach (T t in self)
            {
                action?.Invoke(t);
            }
        }
    }
}